'''
Description: 
Version: 1.0.1
Autor: hrlu.cn
Date: 2022-02-27 21:40:36
LastEditors: hrlu.cn
LastEditTime: 2023-02-21 13:31:13
'''
from django.conf import settings
from django.conf.urls import url
from django.urls import path
from django.views import static

from monitor import views, api

urlpatterns = [
    url(r'^assets/(?P<path>.*)$', static.serve, {'document_root': settings.STATICFILES_ROOT}, name='static'),

    path('', views.index, name='index'),
    path('login/', views.login, name='login'),
    path('ma/', views.ma, name='ma'),
    path('rsia/', views.rsi_analysis, name='rsi_analysis'),
    path('rsie/', views.rsi_extremum, name='rsi_extremum'),
    path('rsif/', views.rsi_filter, name='rsi_filter'),
    path('log/', views.log, name='log'),
    path('top10/', views.top10_holder, name='top10_holder'),
    path('holders/', views.holder_number, name='holder_number'),
    path('achievement/', views.achievement, name='achievement'),
    path('export/', views.export, name='export'),
    path('forecast/', views.forecast, name='forecast'),
    path('fund/', views.fund, name='fund'),
    path('consensus/', views.consensus, name='consensus'),
    path('qcpt/', views.quarter_concept, name='quarter_concept'),
    path('dcpt/', views.daily_concept, name='daily_concept'),
    path('dcpts/', views.daily_concept_stock, name='daily_concept_stock'),
    path('fresh/', views.fresh_price, name='fresh_price'),

    path('api/manual_execute', api.manual_execute, name='execute'),
    path('api/source', api.source, name='source'),
    path('api/update_progress', api.update_progress, name='update_progress'),
    path('api/top10_holder_data', api.top10_holder_data, name='top10_holder_data'),
    path('api/combined_shareholding_data', api.combined_shareholding_data, name='combined_shareholding_data'),
    path('api/combined_stock_shareholding_data', api.combined_stock_shareholding_data, name='combined_stock_shareholding_data'),
    path('api/combine_keywords_data', api.combine_keywords_data, name='combine_keywords_data'),
    path('api/legend_holder_shareholding_data', api.legend_holder_shareholding_data, name='legend_holder_shareholding_data'),
    path('api/stock_legend_holder_data', api.stock_legend_holder_data, name='stock_legend_holder_data'),
    path('api/shareholding_data', api.shareholding_data, name='shareholding_data'),
    path('api/holder_number_data', api.holder_number_data, name='holder_number_data'),
    path('api/achievement_data', api.achievement_data, name='achievement_data'),
    path('api/log', api.log_data, name='log_data'),
    path('api/export_data', api.export_data, name='export_data'),
    path('api/stock_forecast_data', api.stock_forecast_data, name='stock_forecast_data'),
    path('api/fund_portfolio_data', api.fund_portfolio_data, name='fund_portfolio_data'),
    path('api/consensus_data', api.consensus_data, name='consensus_data'),
    path('api/quarter_concept_data', api.quarter_concept_data, name='quarter_concept_data'),
    path('api/fresh_price_data', api.fresh_price_data, name='fresh_price_data'),
    path('api/concept_stock_daily_data', api.concept_stock_daily_data, name='concept_stock_daily_data'),
    path('api/concept_daily_data', api.concept_daily_data, name='concept_daily_data'),
    path('api/stock_concept_history_data', api.stock_concept_history_data, name='stock_concept_history_data'),
    path('api/update_wind_concept_data', api.update_wind_concept_data, name='update_wind_concept_data'),
    path('api/struct_history_data', api.struct_history_data, name='struct_history_data'),
    path('api/trend_date_select_data', api.trend_date_select_data, name='trend_date_select_data'),
    path('api/trend_list_data', api.trend_list_data, name='trend_list_data'),
    # path('api/extre_date_select_data', api.extre_date_select_data, name='extre_date_select_data'),
    # path('api/extre_data', api.extre_data, name='extre_data'),
]

indexes = [
    {'name': 'index', 'desp': "主页", 'icon': 'fas fa-home', 'url': '/', 'subs': []},
    {'name': 'ma', 'desp': "MA交叉筛选", 'icon': 'fas fa-list-alt', 'url': '/ma/', 'subs': []},
    {'name': 'rsi', 'desp': "RSI指标", 'icon': 'fas fa-line-chart', 'url': '#', 'subs': [
        {'name': 'rsia', 'desp': "RSI数据分析", 'icon': 'fas fa-pie-chart', 'url': '/rsia/'},
        {'name': 'rsie', 'desp': "RSI极值监控", 'icon': 'fas fa-area-chart', 'url': '/rsie/'},
        {'name': 'rsif', 'desp': "RSI趋势判断", 'icon': 'fas fa-table', 'url': '/rsif/' },
    ]},
    {'name': 'hold', 'desp': "股东分析", 'icon': 'fas fa-bank', 'url': '#', 'subs': [
        {'name': 'top10', 'desp': "十大流通股东", 'icon': 'fas fa-sort-amount-asc', 'url': '/top10/'},
        {'name': 'holders', 'desp': "股东户数", 'icon': 'fas fa-users', 'url': '/holders/'},
    ]},
    {'name': 'achv', 'desp': "业绩分析", 'icon': 'fas fa-industry', 'url': '#', 'subs': [
        {'name': 'achievement', 'desp': "业绩筛选", 'icon': 'fas fa-filter', 'url': '/achievement/'},
        {'name': 'forecast', 'desp': "业绩预告", 'icon': 'fas fa-file-text', 'url': '/forecast/'},
    ]},
    {'name': 'fund', 'desp': "公募基金", 'icon': 'fas fa-rmb', 'url': '/fund/', 'subs': []},
    {'name': 'consensus', 'desp': "一致预期", 'icon': 'fas fa-random', 'url': '/consensus/', 'subs': []},
    {'name': 'cpt', 'desp': "概念分类", 'icon': 'fas fa-cloud', 'url': '#', 'subs': [
        {'name': 'qcpt', 'desp': "概念板块概况", 'icon': 'fas fa-th-large', 'url': '/qcpt/'},
        {'name': 'dcpt', 'desp': "概念板块综合", 'icon': 'fas fa-calendar-alt', 'url': '/dcpt/'},
        {'name': 'dcpts', 'desp': "个股资金流入", 'icon': 'fas fa-calendar-alt', 'url': '/dcpts/'},
    ]},
    {'name': 'fresh', 'desp': "股价新高", 'icon': 'fas fa-arrow-up ', 'url': '/fresh/', 'subs': []},
    {'name': 'export', 'desp': "数据导出", 'icon': 'fas fa-download', 'url': '/export/', 'subs': []},
    {'name': 'log', 'desp': "操作日志", 'icon': 'fas fa-bars', 'url': '/log/', 'subs': []},
    # {'name': 'more', 'desp': "更多", 'icon': 'fas fa-ellipsis-h', 'url': '#'},
]